package com.sgcc.epri.dcloud.mapper.dm;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.sgcc.epri.dcloud.pojo.TableHead;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface TableHeadMapper extends BaseMapper<TableHead> {

    List<Map<String, Object>> queryObjects();

    List<Map<String, Object>> queryIndexAll(@Param("dataType") String dataType);

    List<Map<String, Object>> queryAssetByObjectId(@Param("objectId") String objectId, @Param("key") String key, @Param("assetType") String assetType);

    void deleteIndexMiddle(@Param("tableHeadId") String tableHeadId);

    void saveIndexs(@Param("tableHeadId") String tableHeadId, @Param("id") String id);

    void deleteAssetTypesIndex(@Param("tableHeadId") String tableHeadId, @Param("indexId") String indexId);

    void deleteAssetTypes(@Param("tableHeadId") String tableHeadId);

    void saveAssetTypes(@Param("tableHeadId") String tableHeadId, @Param("id") String id, @Param("indexId") String indexId);

    String queryAssetNameByAssetTypeId(@Param("strings") List<String> strings);

    String queryAssetNameByAssetId(@Param("strings") List<String> strings);

    String queryIndexNameByIds(@Param("strings") List<String> strings);

    List<Map<String, Object>> queryIndexByType(@Param("tableHeadId") String tableHeadId);

    List<Map<String, Object>> queryAssetByType(@Param("tableHeadId")  String tableHeadId, @Param("indexId")  String indexId);

    List<Map<String, Object>> queryObjectNr();

    List<Map<String, Object>> queryAssetByObjectIdNr(@Param("objectId") String objectId, @Param("key") String key);

    String queryAssetNameByAssetIdNr(@Param("strings") List<String> list);

    List<Map<String, Object>> queryAssetByTypeNr(@Param("tableHeadId")  String tableHeadId, @Param("indexId")  String indexId, @Param("objectId")  String objectId);

    List<Map<String, Object>> queryAssetType();

    String queryNrObjById(@Param("objectId") String objectId);

    void deleteCalResult(@Param("tableHeadId") String tableHeadId);

    List<Map<String, Object>> queryCodeNameOrc();

    void deleteAllContent(@Param("tableHeadId") String tableHeadId);

    List<Map<String, Object>> queryCurrentTreeHead(@Param("treeId") String treeId);

    List<Map<String, Object>> queryAssetByObjectIdList(@Param("objectId") String objectId, @Param("keys") List<String> ids, @Param("assetType") String assetType);
}
